package com.amos.muexamclient.sys.mapper;

import org.apache.ibatis.annotations.Mapper;
import com.amos.muexamcore.core.BaseMapper;
import com.amos.muexamclient.sys.entity.SysDeptEntity;
import com.amos.muexamclient.sys.service.dto.SysDeptDTO;
import org.apache.ibatis.annotations.Param;
import org.springframework.security.core.parameters.P;

import java.util.List;


/**
 * Copyright © 2018 五月工作室. All rights reserved.
 *
 * @Package com.amos.muexamclient.sys.mapper
 * @ClassName SysDeptDao
 * @Description TODO
 * @Author Amos
 * @Modifier
 * @Date 2020-03-15 10:39:17
 * @Version 1.0
 **/
@Mapper
public interface SysDeptMapper extends BaseMapper<SysDeptEntity, SysDeptDTO> {


    List<String> selectDeptListByRoleId(@Param("roleId") String id);

    List<SysDeptDTO> getDeptNameAndParentId(@Param("deptName") String deptName, @Param("parentId") String parentId);

    int hasChildByDeptId(@Param("deptId") String deptId);

    int checkDeptExistUser(@Param("deptId") String deptId);
}